# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.AssuredWorkloads.V1.Model.GoogleCloudAssuredworkloadsV1AcknowledgeViolationRequest do
  @moduledoc """
  Request for acknowledging the violation

  ## Attributes

  *   `acknowledgeType` (*type:* `String.t`, *default:* `nil`) - Optional. Acknowledge type of specified violation.
  *   `comment` (*type:* `String.t`, *default:* `nil`) - Required. Business justification explaining the need for violation acknowledgement
  *   `nonCompliantOrgPolicy` (*type:* `String.t`, *default:* `nil`) - Optional. This field is deprecated and will be removed in future version of the API. Name of the OrgPolicy which was modified with non-compliant change and resulted in this violation. Format: projects/{project_number}/policies/{constraint_name} folders/{folder_id}/policies/{constraint_name} organizations/{organization_id}/policies/{constraint_name}
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :acknowledgeType => String.t() | nil,
          :comment => String.t() | nil,
          :nonCompliantOrgPolicy => String.t() | nil
        }

  field(:acknowledgeType)
  field(:comment)
  field(:nonCompliantOrgPolicy)
end

defimpl Poison.Decoder,
  for:
    GoogleApi.AssuredWorkloads.V1.Model.GoogleCloudAssuredworkloadsV1AcknowledgeViolationRequest do
  def decode(value, options) do
    GoogleApi.AssuredWorkloads.V1.Model.GoogleCloudAssuredworkloadsV1AcknowledgeViolationRequest.decode(
      value,
      options
    )
  end
end

defimpl Poison.Encoder,
  for:
    GoogleApi.AssuredWorkloads.V1.Model.GoogleCloudAssuredworkloadsV1AcknowledgeViolationRequest do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
